package bookExercise;

import java.util.function.Function;

public class A13FunctionDemo {
    Function<Integer[],String> function = (n)->{
        StringBuilder str = new StringBuilder();
        for(Integer num :n){
            str.append(num);
            str.append('.');
        }
        str.deleteCharAt(str.length()-1);
        return str.toString();
    };
    public static void main(String[] args) {
        Integer[] ip = {192,168,1,1};
        A13FunctionDemo demo =new A13FunctionDemo();
        System.out.println(demo.function.apply(ip));
    }
}
